mmc: Fix mmc_send_status()
authorMarek Vasut <[email protected]>
Wed, 10 Aug 2011 07:24:48 +0000 (09:24 +0200)
committerAndy Fleming <[email protected]>
Sun, 4 Sep 2011 23:03:02 +0000 (18:03 -0500)
The mmc_send_status() function sets cmd.arg = 0. That's incorrect, so fix it.

Signed-off-by: Marek Vasut <[email protected]>
Acked-by: Andy Fleming <[email protected]>
Tested-by: Lei Wen <[email protected]>
drivers/mmc/mmc.c

index 7e703c0ec6e293bc7ee5e19fcfe622161a7ee934..391bc2bafa0f3393d377425d995ac9939fc1831b 100644 (file)
@@ -115,7 +115,8 @@ int mmc_send_status(struct mmc *mmc, int timeout)
 
        cmd.cmdidx = MMC_CMD_SEND_STATUS;
        cmd.resp_type = MMC_RSP_R1;
-       cmd.cmdarg = 0;
+       if (!mmc_host_is_spi(mmc))
+               cmd.cmdarg = mmc->rca << 16;
        cmd.flags = 0;
 
        do {